module fulladder_1bit(A,B,Cin,Sum,Cout);

input A,B,Cin;
output Sum, Cout;

wire xorAB, andAB, andC;

xor x00(xorAB,A,B);
and and00(andAB,A,B);
and and01(andC,xorAB,Cin);
xor x01(Sum,xorAB,Cin);
or or01(Cout,andAB,andC);

endmodule
